package com.orilore.gb.biz;

import java.util.List;

import org.apache.ibatis.session.SqlSession;

import com.orilore.gb.dao.NTeacherDao;
import com.orilore.gb.entity.NTeacher;
import com.orilore.gb.util.MySessionFactory;

public class NTeacherBiz {
	
	private NTeacherDao dao;
	
	
	public List<NTeacher> findAllTeachers(){
		
		List<NTeacher> list = null;
		
		
		try {
			SqlSession session = MySessionFactory.getSession();
			
			dao = session.getMapper(NTeacherDao.class);
			
			
			list = dao.selectAllTeacher2();
			
			
			MySessionFactory.closeSession(session);
			
			
			
		} catch (Exception e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		
		
		
		return list;
		
		
	}

}
